<template>
    <div>
        <v-header>
            <div slot="left" class="backs_icon"></div>
        </v-header>
        <div class="main_allScroll drawbackAccount" >
            <group title="收款账户信息">
                <cell title="全称" :value="config.drawbackAccountName"></cell>
                <cell title="账户" :value="config.drawbackAccountNumber"></cell>
                <cell title="开户行" :value="config.drawbackAccountBank"></cell>
            </group>
            <div class="foot_add content" v-on:click="gotoPage">
                <button class="btns">提交已充值信息</button>
            </div>
        </div>
    </div>
</template>
<script>
    import {Cell, Group} from 'vux'
    import {mapActions, mapState} from 'vuex'
    import {SETCONFIG} from "store/config";

    export default {
        components: {
            Cell,
            Group,
        },
        name: "rechargeMethod",
        activated(){
            this.init();
        },
        methods: {
            ...mapActions({SETCONFIG}),
            init(){
                this.configManage();
            },
            configManage(){
                this.$ajax.finance.configManage()
                    .then((res)=>{
                        for(let item in res.body.content){
                            if(item != 'drawbackAccountBank' && item != 'drawbackAccountName' && item != 'drawbackAccountNumber'){
                                res.body.content[item] = Number(res.body.content[item])
                            }
                        }
                        this.SETCONFIG(res.body.content);
                    })
            },
            gotoPage() {
                this.$router.push({path: '/UnderLineRecharge'})
            }
        },
        computed: mapState({config: state => state.config})
    }
</script>
<style >
    .drawbackAccount .weui-cell__ft{
        font-size: .28rem ;
    }
</style>